package com.gxa.learning.pc.mapper;

import com.gxa.learning.core.pojo.Question;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;
import java.util.Map;

/**
 * @Author ChenJ
 * @date 2021/12/03 14:22
 **/
public interface QuestionMapper extends Mapper<Question> {
    /**
     * 获取选择题目
     *
     * @param id 题库id
     * @return
     */
    List<Question> getChoose(Long id);

    /**
     * 获取判断题目
     *
     * @param id 题库id
     * @return
     */
    List<Question> getJudge(Long id);

    /**
     * 获取学员已经考完试的选择题的题目以及填写的答案
     *
     * @param uId
     * @param qId
     * @return
     */
    List<Map<String, Object>> getUserChoose(Long uId, Long qId);


    /**
     * 获取学员已经考完试的判断题的题目以及填写的答案
     *
     * @param uId
     * @param qId
     * @return
     */
    List<Map<String, Object>> getUserJudge(Long uId, Long qId);
}
